package com.itheima.sh.HomeWork;


//1.导包
import java.util.Scanner;

public class Test01 {
    public static void main(String[] args) {
        //2.创建键盘录入类对象
        Scanner sc = new Scanner(System.in);
        //3.提示信息
        System.out.println("请输入数据:");
        //4.获取输入的数据
        String s = sc.next();
        //5.定义一个空字符串保存反转后的字符串
        String s1 = "";
        //6.使用循环进行反转
        for (int i = s.length() - 1; i >= 0; i--) {
            s1 += s.charAt(i);
        }
        System.out.println(s1);



    }
}
